<%@page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>

<head>
    <title><s:text name="accounts"/></title>   
</head>

<link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/ajax_theme.css"/>

<script type="text/javascript">
	//Loading accounts widgets to the corresponding DIV containers via AJAX calls
	<s:iterator value="accounts" var="current" status="status">
		$('#account${current.id}').ready(function(){
			$('#account${current.id}').load('widgets/DisplayAccount?id=${current.id}');
		});
	</s:iterator>
	$('#account-1').ready(function(){
		$('#account-1').load('widgets/DisplayAccount?id=-1');
	});
</script>

<div class="panel" style="width: 472px;">
	<s:div cssClass="panelTitle">
		<s:text name="accounts"/>
	</s:div>

	<s:iterator value="accounts" var="current" status="status">
		<div id="panel${current.id}" class="accountView panel">
			<div id="account${current.id}"></div>
		</div>
	</s:iterator>
	
	<div id="panel-1" class="accountAdd">
		<div id="account-1"></div>
	</div>
</div>